using System;
using System.Collections.Generic;


namespace Gfw.Models.Stock
{
	[Serializable]
	public partial class StkWaitbargainpool: IEquatable<StkWaitbargainpool>
	{

		#region Private Members

		private string _id; 
		private string _userid; 
		private decimal _agencyprice; 
		private decimal _agencycount; 
		private int _tradetype; 
		private DateTime? _agencydate; 
		private string _agencyid; 
		private int _accounttype; 		
		#endregion

		#region Constructor

		public StkWaitbargainpool()
		{
			_id = String.Empty; 
			_userid = String.Empty; 
			_agencyprice = 0; 
			_agencycount = 0; 
			_tradetype = 0; 
			_agencydate = null; 
			_agencyid = String.Empty; 
			_accounttype = 0; 
		}
		#endregion // End of Default ( Empty ) Class Constuctor

		#region Public Properties
			
		public virtual string Id
		{
			get
			{ 
				return _id;
			}

			set	
			{	
				if( value == null )
					throw new ArgumentOutOfRangeException("Null value not allowed for Id", value, "null");
				
				if(  value.Length > 40)
					throw new ArgumentOutOfRangeException("Invalid value for Id", value, value.ToString());
				
				_id = value;
			}
		}
			
		public virtual string UserId
		{
			get
			{ 
				return _userid;
			}

			set	
			{	
				if(  value != null &&  value.Length > 40)
					throw new ArgumentOutOfRangeException("Invalid value for UserId", value, value.ToString());
				
				_userid = value;
			}
		}
			
		public virtual decimal AgencyPrice
		{
			get
			{ 
				return _agencyprice;
			}
			set
			{
				_agencyprice = value;
			}

		}
			
		public virtual decimal AgencyCount
		{
			get
			{ 
				return _agencycount;
			}
			set
			{
				_agencycount = value;
			}

		}
			
		public virtual int TradeType
		{
			get
			{ 
				return _tradetype;
			}
			set
			{
				_tradetype = value;
			}

		}
			
		public virtual DateTime? AgencyDate
		{
			get
			{ 
				return _agencydate;
			}
			set
			{
				_agencydate = value;
			}

		}
			
		public virtual string AgencyId
		{
			get
			{ 
				return _agencyid;
			}

			set	
			{	
				if(  value != null &&  value.Length > 40)
					throw new ArgumentOutOfRangeException("Invalid value for AgencyId", value, value.ToString());
				
				_agencyid = value;
			}
		}
			
		public virtual int AccountType
		{
			get
			{ 
				return _accounttype;
			}
			set
			{
				_accounttype = value;
			}

		}
			
				
		#endregion 

		#region Public Functions

		#endregion //Public Functions

		#region IEquatable members

		public virtual bool Equals(StkWaitbargainpool other)
		{
			if (other == this)
				return true;
		
			return ( other != null ) &&
				( this._id == other.Id );
				   
		}

		#endregion
		
	}
}
